/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.sai.sql;

/**
 *
 * @author Eduardo
 */
public class SqlAlumno  {
    public static final String SELECT;
    public static final String SELECT_ALL;
    public static final String INSERT;
    public static final String UPDATE_AFTER_UPDATE;
    
    static {
        StringBuilder qryBuilder = new StringBuilder();

        qryBuilder = new StringBuilder();
        qryBuilder.append("SELECT * FROM articulo WHERE nombre = ?");
        SELECT = qryBuilder.toString();

        qryBuilder = new StringBuilder();
        qryBuilder.append("SELECT * FROM alumno ORDER BY Matricula ASC");
        SELECT_ALL = qryBuilder.toString();

        qryBuilder = new StringBuilder();
        qryBuilder.append("INSERT INTO alumno(Nombre,ApellidoMaterno,ApellidoPaterno,Matricula,Grupo,NombreProyecto) values (?, ?, ?, ?, ?, ?)");
        INSERT = qryBuilder.toString();
        
        qryBuilder = new StringBuilder();
        qryBuilder.append("UPDATE autores SET estado = 'Activo' WHERE id_autor = ?");
        UPDATE_AFTER_UPDATE = qryBuilder.toString();

     }
    
}
